package com.ojoin.trade.common.web.domain;


import java.util.Date;

import javax.validation.constraints.NotNull;

/**
 * 通知数据
 */
public class Notification extends BaseEntity<Notification> {

    /**
     *  接收通知的用户
     */
    @NotNull(message = "不允许为空")
    private Integer userId;

    /**
     * 通知类型
     */
    @NotNull(message = "不允许为空")
    private NotificationType type;

    private String title;
    /**
     * 通知内容
     */
    private String content;

    /**
     * 通知时间
     */
    private Date date;

    /**
     * 是否已读
     */
    private Boolean read = Boolean.FALSE;

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(final Integer userId) {
        this.userId = userId;
    }

    public NotificationType getType() {
        return type;
    }

    public void setType(final NotificationType type) {
        this.type = type;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(final String title) {
        this.title = title;
    }

    public String getContent() {
        return content;
    }

    public void setContent(final String content) {
        this.content = content;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(final Date date) {
        this.date = date;
    }

    public Boolean getRead() {
        return read;
    }

    public void setRead(final Boolean read) {
        this.read = read;
    }

	@Override
	public Date getRowUpdateTime() {
		return null;
	}

	@Override
	public void setRowUpdateTime(Date rowUpdateTime) {
		
	}

	@Override
	public Date getRowCreateTime() {
		return null;
	}

	@Override
	public void setRowCreateTime(Date rowCreateTime) {
		
	}

	@Override
	public String getTableName() {
		return "sys_notification";
	}

	@Override
	public void preInsert() {
		
	}

	@Override
	public void preUpdate() {
		
	}
}
